<?php
/**
 * ExtNumberField class file
 *
 * @author TrueSoftware B.V. (The Netherlands)
 * @link http://www.ext4yii.com
 * @copyright Copyright 2007-2010 TrueSoftware B.V. all rights reserved.
 * @license http://www.ext4yii.com/license/
 *          EVALUATION VERSION - NOT FOR COMMERCIAL USE OR DISTRIBUTION.
 * @version 0.7.2
 */

class ExtNumberField extends ExtTextField
{
    /**
     * Gets the value of ExtJS allowDecimals property
     * @return Boolean 
     */
    public function getAllowDecimals()
    {
    	return $this->getConfig("allowdecimals");
    }

    /**
     * Sets the value of ExtJS allowDecimals property
     * @param Boolean $value 
     */
    public function setAllowDecimals($value)
    {
    	$this->setConfig("allowdecimals",$value);
    }

    /**
     * Gets the value of ExtJS allowNegative property
     * @return Boolean 
     */
    public function getAllowNegative()
    {
    	return $this->getConfig("allownegative");
    }

    /**
     * Sets the value of ExtJS allowNegative property
     * @param Boolean $value 
     */
    public function setAllowNegative($value)
    {
    	$this->setConfig("allownegative",$value);
    }

    /**
     * Gets the value of ExtJS baseChars property
     * @return String 
     */
    public function getBaseChars()
    {
    	return $this->getConfig("basechars");
    }

    /**
     * Sets the value of ExtJS baseChars property
     * @param String $value 
     */
    public function setBaseChars($value)
    {
    	$this->setConfig("basechars",$value);
    }

    /**
     * Gets the value of ExtJS decimalPrecision property
     * @return Number 
     */
    public function getDecimalPrecision()
    {
    	return $this->getConfig("decimalprecision");
    }

    /**
     * Sets the value of ExtJS decimalPrecision property
     * @param Number $value 
     */
    public function setDecimalPrecision($value)
    {
    	$this->setConfig("decimalprecision",$value);
    }

    /**
     * Gets the value of ExtJS decimalSeparator property
     * @return String 
     */
    public function getDecimalSeparator()
    {
    	return $this->getConfig("decimalseparator");
    }

    /**
     * Sets the value of ExtJS decimalSeparator property
     * @param String $value 
     */
    public function setDecimalSeparator($value)
    {
    	$this->setConfig("decimalseparator",$value);
    }

    /**
     * Gets the value of ExtJS fieldClass property
     * @return String 
     */
    public function getFieldClass()
    {
    	return $this->getConfig("fieldclass");
    }

    /**
     * Sets the value of ExtJS fieldClass property
     * @param String $value 
     */
    public function setFieldClass($value)
    {
    	$this->setConfig("fieldclass",$value);
    }

    /**
     * Gets the value of ExtJS maxText property
     * @return String 
     */
    public function getMaxText()
    {
    	return $this->getConfig("maxtext");
    }

    /**
     * Sets the value of ExtJS maxText property
     * @param String $value 
     */
    public function setMaxText($value)
    {
    	$this->setConfig("maxtext",$value);
    }

    /**
     * Gets the value of ExtJS maxValue property
     * @return Number 
     */
    public function getMaxValue()
    {
    	return $this->getConfig("maxvalue");
    }

    /**
     * Sets the value of ExtJS maxValue property
     * @param Number $value 
     */
    public function setMaxValue($value)
    {
    	$this->setConfig("maxvalue",$value);
    }

    /**
     * Gets the value of ExtJS minText property
     * @return String 
     */
    public function getMinText()
    {
    	return $this->getConfig("mintext");
    }

    /**
     * Sets the value of ExtJS minText property
     * @param String $value 
     */
    public function setMinText($value)
    {
    	$this->setConfig("mintext",$value);
    }

    /**
     * Gets the value of ExtJS minValue property
     * @return Number 
     */
    public function getMinValue()
    {
    	return $this->getConfig("minvalue");
    }

    /**
     * Sets the value of ExtJS minValue property
     * @param Number $value 
     */
    public function setMinValue($value)
    {
    	$this->setConfig("minvalue",$value);
    }

    /**
     * Gets the value of ExtJS nanText property
     * @return String 
     */
    public function getNanText()
    {
    	return $this->getConfig("nantext");
    }

    /**
     * Sets the value of ExtJS nanText property
     * @param String $value 
     */
    public function setNanText($value)
    {
    	$this->setConfig("nantext",$value);
    }

    /**
     * @description maps to the setMaxValue function in Ext.form.NumberField
     * @param sender String -
     * @param value Number - 
     */
    public static function setMaxValue_OnAjax($value,$sender=null)
    {
    	ExtWidget::checkSetAjaxRequestValue('setMaxValue(%s)',
    		array($value),
    			 $sender);
    }

    /**
     * @description maps to the setMinValue function in Ext.form.NumberField
     * @param sender String -
     * @param value Number - 
     */
    public static function setMinValue_OnAjax($value,$sender=null)
    {
    	ExtWidget::checkSetAjaxRequestValue('setMinValue(%s)',
    		array($value),
    			 $sender);
    }

    
    public function __construct()
    {
        parent::__construct();
        $this->configmap = array_merge($this->configmap,array(
            'allowdecimals' => 'allowDecimals',
            'allownegative' => 'allowNegative',
            'basechars' => 'baseChars',
            'decimalprecision' => 'decimalPrecision',
            'decimalseparator' => 'decimalSeparator',
            'fieldclass' => 'fieldClass',
            'maxtext' => 'maxText',
            'maxvalue' => 'maxValue',
            'mintext' => 'minText',
            'minvalue' => 'minValue',
            'nantext' => 'nanText'
        ));



        $this->setXType('numberfield');
        $this->setXClass('Ext.form.NumberField');
    }    
}
?>